﻿using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using HZ.MBSM.DBUtility;
using HZ.MBSM.Model;

public partial class Su_Boardinfo : System.Web.UI.Page
{
    public string id = "", strAccountName = "", strContent = "", strExplain = "", strTitle = "";
    protected void Page_Load(object sender, EventArgs e)
    {
        id = SysFun.IsSQL(Request.QueryString["id"]);
        if (!IsPostBack)
        {
            InitPage();
        }
    }
    private void InitPage()
    {
        string strSql = "select board.*,account.accountname from board inner join account on board.accountid=account.accountid where id=" + id + "";
        Db db = new Db();
        System.Data.IDataReader dr;
        dr = db.DataReader(strSql);
        if (dr.Read())
        {
            strAccountName = SysFun.ToTrim(dr["AccountName"]);
            strContent = SysFun.ToTrim(dr["Content"]);
            strExplain = SysFun.ToTrim(dr["Explain"]);
            strTitle = SysFun.ToTrim(dr["Title"]);
        }
        dr.Close();
        dr.Dispose();
        db.Close();
    }

}
